<template>
	<view class="container">
		<view class="recordCont">
			<view class="recordItem" v-for="item in recordList">
				<view class="recordDetail">
					<view class="recordName">{{item.nick_name}}</view>
				</view>
				<view class="prize">
					+{{item.count}}
				</view>
			</view>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				recordList:[],
				id:'',
				page: 1
			}
		},
		onReachBottom() {
			console.log('触底了')
			this.page++
			this.init()
		},
		onLoad(options) {
			this.id=options.id
			this.init()
		},
		
		methods: {
			init(){
				this.$http('api/forge_task/rankingList', {
					id: this.id,
					page: this.page
				}).then(res => {
					console.log(res)
					// this.recordList = this.recordList.concat(res)
				})
			}
		}
	}
</script>

<style scoped lang="less">
.container{
	width: 100%;
	.recordCont{
			width: 96%;
			margin: 0 auto;
			.recordItem{
				display: flex;
				justify-content: space-between;
				align-items: center;
				padding: 20rpx 10rpx;
				.recordDetail{
					.recordName{
						font-size: 32rpx;
						font-weight: bold;
					}
					.recordTime{
						margin-top: 20rpx;
						font-size: 26rpx;
						color: #999999;
					}
				}
				.prize{
					font-size: 34rpx;
					color: #1690FD;
					font-weight: bold;
				}
			}
	}
}
</style>
